<template>
  <div class="table-header-layout">
    <div class="table-header-title">
      {{ props.header }}
      <slot name="headerAction" />
    </div>
    <div v-if="props.comment" style="color: #484b55; font-size: 12px;">
      {{ props.comment }}
    </div>
    <slot name="headerExtra" />
  </div>
</template>

<script setup lang="ts">

const props = withDefaults(defineProps<{
  header: any,
  comment?: any,
}>(), {
  header: "",
});

</script>

<style scoped>
.table-header-layout {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  font-size: 12px;
  align-items: stretch;
}

.table-header-title {
  display: flex;
  flex: 1;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px 24px 16px;
  color: #484b55;
  font-size: 18px;
  font-weight: bold;
}

</style>
